using System.IO;
using AOT.Game.Misc;
using UnityEngine;

namespace Wxy.Res.Config
{
    /// <summary>
    /// 运行时的配置文件
    /// 之后会全部打入配置文件中
    /// </summary>
    public static class ResCfg
    {
        public static string LOCAL_MANIFEST
        {
            get
            {
#if !UNITY_EDITOR
              return Application.persistentDataPath +"/ABOutputRes/manifest.json";
#else
                return Utils.GetNowFullPath("/Output/ABRes/manifest.json");
#endif
            }
        }

        public static string AB_RES
        {
            get
            {
#if !UNITY_EDITOR
              return Application.persistentDataPath +"/ABOutputRes/";
#else
                return Utils.GetNowFullPath("/Output/ABRes/");
#endif
            }
        }

        public static string DLL_PATH
        {
            get => Application.persistentDataPath + "/ABOutputRes/HotUpdate.dll.bytes";
        }

        //----Unity服务器地址
        public static string SERVER_RES
        {
            get
            {
#if UNITY_EDITOR
                return "http://10.85.73.22:8091/ABRes/";
#else
                return "http://10.85.73.22:8091/ABRes/";
#endif
            }
        }
#if UNITY_EDITOR
        public static readonly string RES_SERVER_LOCAL = Utils.GetNowFullPath("/Output/ABRes/");
#endif
    }
}